﻿Module modGlobalData

    '数据库关联
    Public DBacs As New clsOdbcDbIf
    Public g_fDBconnect As Boolean
    Public g_iDBconnResult As Integer
    Public g_szDBIpAddress As String

    '全局变量
    Public g_szInitFileName As String
    '用户信息
    Public g_Current_UserID As String
    Public g_Current_UserName As String
    Public g_Current_WorkShop As String
    Public g_Current_Classes As String
    '当前派工单信息
    Public g_Current_PGD_ID As String
    Public g_Current_PJ_Name As String
    Public g_Current_JP_Type As String
    Public g_Current_FLB_Type As String
    Public g_Current_GJB_Type As String
    Public g_Current_PROD_SPEC As String

    Public g_BHJ_LOC As String '设定保护胶画面，在【硫化前缓冲区画面】所选择库位号

    Public Enum CK_TYPE
        FLB '法兰板 仓库
        PW  '抛瓦后 仓库
        GJB '骨架板 仓库
        CP  '组装成品 仓库
    End Enum
    Public Structure ServerDBacsTYPE
        Dim szDrive As String
        Dim szIPadr As String
        Dim szDsn As String
        Dim szDbn As String
        Dim szUid As String
        Dim szPas As String
        Dim iOver As Integer
    End Structure
    Public g_Server As ServerDBacsTYPE

    Public Const INSERT_TYPE As String = "I"
    Public Const UPDATE_TYPE As String = "U"
    Public Const DELETE_TYPE As String = "D"

    '工厂
    Public Const g_factory_id = "TS"

    '车间ID
    Public Const g_ws_gjb As String = "GJB" '骨架板
    Public Const g_ws_jp As String = "JP"   '胶片
    Public Const g_ws_lh As String = "LH"   '硫化

    '登录用户名
    Public g_LoginUser As String = ""

    '设备类型
    Public Const g_equipType_jxb As String = "JXB"  '机械臂
    Public Const g_equipType_yjb As String = "YJB"  '运胶臂
    Public Const g_equipType_ybb As String = "YBB"  '运板臂
    Public Const g_equipType_dzc As String = "DZC"  '电子秤
    Public Const g_equipType_smq As String = "SMQ"  '扫描枪
    Public Const g_equipType_dpdzc As String = "DPDZC" '端片电子秤
    Public Const g_equipType_bhjdzc As String = "BHJDZC" '保护胶电子秤
    Public Const g_equiptype_LHJ As String = "LHJ" '硫化机
    Public Const g_equiptype_AGV As String = "AGV" 'AGV

    '保存MESSAGE
    Public htMsgMst As New Hashtable

    '主档型号
    Public Const FLBXH As String = "01" '法兰板型号
    Public Const GJBXH As String = "02" '骨架板型号
    Public Const JLXH As String = "03"  '胶料型号
    Public Const XZXH As String = "04"  '芯座型号
    Public Const WXCJ As String = "05"  '外协厂家
    Public Const MJXH As String = "06"  '模具
    Public Const KWZD As String = "07"  '库位
    Public Const BMZD As String = "08"  '部门
    Public Const LHJXH As String = "09" '硫化机型号
    Public Const QXZD As String = "10" '权限

    Public Const TM_WARNING_PW As String = "1"  '抛丸   期限管理
    Public Const TM_WARNING_PS As String = "2"  '喷砂   期限管理
    Public Const TM_WARNING_PJ As String = "3"  '喷胶   期限管理
    Public Const TM_WARNING_HLJ As String = "4" '混炼胶 期限管理
    Public Const TM_WARNING_LH As String = "5"  '待硫化 期限管理

    '胶面方向
    Public Const JMFX_UP As String = "朝上"
    Public Const JMFX_DOWN As String = "朝下"
End Module
